package com.tencent.ied.bk.entity;

import com.fasterxml.jackson.annotation.JsonIgnore;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.concurrent.atomic.AtomicInteger;

/**
 * @author chen_yu
 * @date 2021/3/11 2:34
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class BaseAbstractInfo {

    /**
     * 摘要ID
     */
    private Integer id;
    /**
     * 摘要信息的内容
     */
    private String content;
    /**
     * 摘要内容中包含的单词
     */
    @JsonIgnore
    private String[] words;
    /**
     * 搜索次数
     */
    private AtomicInteger searchCount;


    public BaseAbstractInfo(String content, AtomicInteger searchCount) {
        this.content = content;
        this.searchCount = searchCount;
    }

    @Override
    public String toString() {
        return "BaseAbstractInfo{" +
                "id=" + id + ", searchCount=" + searchCount + '}';
    }
}
